package com.qf.utils;

import java.util.List;

public class PageBean<T> {
    private int curpage;
    private boolean hasPrev;
    private boolean hasNext;
    private boolean isFirst;
    private boolean isLast;
    private int prev;
    private int next;
    private int first = 1;
    private int last;
    private int counts;
    private int pages;
    private List<T> list;

    public int getCurpage() {
        return curpage;
    }

    public void setCurpage(int curpage) {
        this.curpage = curpage;
    }

    public boolean getHasPrev() {
        return curpage > 1;
    }

    public boolean getHasNext() {
        return curpage < pages;
    }

    public boolean getIsFirst() {
        return curpage == 1;
    }

    public boolean getIsLast() {
        return curpage == pages;
    }

    public int getPrev() {
        return curpage - 1;
    }

    public int getNext() {
        return curpage + 1;
    }

    public int getFirst() {
        return first;
    }

    public int getLast() {
        return pages;
    }

    public int getCounts() {
        return counts;
    }

    public void setCounts(int counts) {
        this.counts = counts;
    }

    public int getPages() {
        return pages;
    }

    public void setPages(int pages) {
        this.pages = pages;
    }

    public List<T> getList() {
        return list;
    }

    public void setList(List<T> list) {
        this.list = list;
    }
}